package com.dream.technology.db.dao;

import com.dream.technology.db.entity.RcRuleItem;
import com.dream.technology.db.entity.RcRuleItemQuery;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface RcRuleItemMapper {
    int countByExample(RcRuleItemQuery example);

    int deleteByExample(RcRuleItemQuery example);

    int deleteByPrimaryKey(Long id);

    int insert(RcRuleItem record);

    int insertSelective(RcRuleItem record);

    List<RcRuleItem> selectByExample(RcRuleItemQuery example);

    RcRuleItem selectByPrimaryKey(Long id);

    int updateByExampleSelective(@Param("record") RcRuleItem record, @Param("example") RcRuleItemQuery example);

    int updateByExample(@Param("record") RcRuleItem record, @Param("example") RcRuleItemQuery example);

    int updateByPrimaryKeySelective(RcRuleItem record);

    int updateByPrimaryKey(RcRuleItem record);

    /**
     * 查询指定id的规则集合
     * 配置规则集验证
     * @param ids
     * @return
     */
    List<RcRuleItem> selectByIdInList(List<Long> ids);

    /**
     * 批量插入item
     * @param record
     * @return
     */
    int insertList(List<RcRuleItem> record);
}